package com.woniuxy.service.impl;

import com.woniuxy.daos.TbHospitalDao;
import com.woniuxy.entitys.TbHospital;
import com.woniuxy.service.HospitalService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class HospitalServiceImpl implements HospitalService {
    @Autowired
    private TbHospitalDao tbHospitalDao;
    @Override
    public List<TbHospital> getAllHospital() {
        List<TbHospital> allHospital = tbHospitalDao.getAllHospital();
        return allHospital;
    }

    @Override
    public int getallHospital() {
        return tbHospitalDao.getallHospital();
    }

    @Override
    public List<TbHospital> getHospitalList() {
        return tbHospitalDao.selAllHospital();
    }
    public List<TbHospital> getHospitalAndDepartment() {
        return tbHospitalDao.getHospitalAndDepartment();
    }
}
